#include <stdio.h>
#include <math.h>
int main()
{
	double x, y, z;
	do{
		scanf("%lf", &x);
	}while(x<=0);
	do{
		scanf("%lf", &y);
	}while(y<=0);
	z = sqrt(x*x+y*y);
	printf("%lf", z);
	return 0;
}
